package com.kelp.codetoolkit.enums

/**
 * @author: liuyuebai
 * @date: 2025/1/22 08:38
 * @description:
 */
enum class MVCLayeringEnum(val packageName:String,val desc:String) {

    ENTITY("entity","实体包名"),
    SERVICE("service","服务层接口包名"),
    SERVICE_IMPL("impl","服务实现接口包名"),
    DAO("dao","数据访问对象包名")

    ;

    companion object{

        fun isEntity(packageName:String):Boolean{
            return ENTITY.packageName == packageName
        }

        fun isService(packageName:String):Boolean{
            return SERVICE.packageName == packageName
        }

        fun isServiceIMPL(packageName:String):Boolean{
            return SERVICE_IMPL.packageName == packageName
        }
        fun isDao(packageName:String):Boolean{
            return DAO.packageName == packageName
        }
    }
}